class Person {
    public name: string
    public age: number
    constructor(name:string,age:number){
        console.log('Person constructor',this)
        this.name = name
        this.age = age 
    }
    public say(){
        console.log('hei : Person',this)
    }
}

class Student extends Person{
    public grade:number

    constructor(grade:number,name:string,age:number){
        super(name,age)
        console.log('student constructor',this)
        this.grade = grade
    }

    public say(){
        super.say()
        console.log('hei : Student',this)
    }
}

let xiaofang = new Student(1,'少凡',22)
xiaofang.say()
